﻿/*添加*/
function common_add(title, url, w, h) {
    layer_show(title, url, w, h);
}
/*编辑*/
function common_edit(title, url, id, w, h) {
    layer_show(title, url, w, h);
}
/*删除*/
function common_del(obj, id) {
    layer.confirm('删除须谨慎，确认要删除吗？', function (index) {
        $.ajax({
            type: 'POST',
            url: '',
            dataType: 'json',
            success: function (data) {
                $(obj).parents("tr").remove();
                layer.msg('已删除!', { icon: 1, time: 1000 });
            },
            error: function (data) {
                console.log(data.msg);
            },
        });
    });
}
/**
 * 关闭当前弹出层
 * @param {any} reload 是否刷新父层页面
 */
function closePageLayer(reload) {
    if (reload)
        parent.location.reload();
    var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
    parent.layer.close(index); //再执行关闭
}
/**
 * 关闭当前页面弹出层
 * @param {any} reload 是否刷页面
 */
function closePageLayerThis(reload) {
    if (reload)
        layer.location.reload();
    layer.close(1); //再执行关闭
}
/**
 * 弹出确定提示
 * @param {any} txt  提示文本
 * @param {any} icon 文本图标 0-7
 * @param {any} fu  回调方法
 */
function popupAlertFu(txt, icon, fu) {
    layer.alert(txt, { skin: 'layui-layer-molv', icon: icon, title: '温馨提示' }, function (data) { if (fu) { fu(data); }; });
}
function popupAlert(txt, icon, fu) {
    layer.alert(txt, { skin: 'layui-layer-molv', icon: icon, title: '温馨提示' }, function (data) { if (fu) { fu(data); }; });
}

function popupAlertEza(txt) {
    layer.alert(txt, { skin: 'layui-layer-molv', icon: 2, title: '温馨提示' }, function (data) { layer.close(data); });
}
/**
 * 弹出选择确定层
 * @param {any} txt 提示文本
 * @param {any} icon 文本图标 0-7
 * @param {any} fu 回调方法 
 */
function popupConfirm(txt, icon, fu) {
    layer.confirm(txt, { skin: 'layui-layer-molv', icon: icon, title: '温馨提示' }, function (data) { if (fu) { fu(data); }; });
}


function product_add(title, url) {
    var index = layer.open({
        type: 2,
        title: title,
        content: url
    });
    layer.full(index);
}

/**
 * 处理ajax post请求方法
 * @param {any} url 请求地址
 * @param {any} d  请求参数
 * @param {any} fn  回调方法
 * @param {any} loading  是否启用遮罩层
 */
function SubmitFormForAjax(url, d, fn, loading) {
    var loadingbar = setTimeout(function () {
        if (loading) {
            layer.msg('处理中..', {
                icon: 16
                , shade: 0.3
                , time: false
            });
        }
    }, 2000);
    $.ajax({
        type: "POST",
        url: url,
        data: d,
        beforeSend: function () {
            loadingbar;
        },
        success: function (data) {
            clearTimeout(loadingbar);
            if (fn) {
                fn(data);
            }
        },
        error: function () {
            clearTimeout(loadingbar);
        }
    });
}

/**
 * 2021-07-28T00:00:00 转 2021-07-06 14:23:00
 * @param {any} timestamp 日期字符串
 */
function transformTimestamp(timestamp) {
    let a = new Date(timestamp).getTime();
    const date = new Date(a);
    const Y = date.getFullYear() + '-';
    const M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';
    const D = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()) + '  ';
    const h = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours()) + ':';
    const m = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()) + ':';
    const s = date.getSeconds(); // 秒
    const dateString = Y + M + D + h + m + s;
    return dateString;
}



//PLC 报警代码转换  所有报警代码
function allPlcAlrmShow(id) {
    var alrmCode = id;
    var alrmValue = "0";
    if (parseInt(alrmCode) > 0) {
        if (alrmCode == 1) {
            alrmValue = "入料超时报警";
        }
        else if (alrmCode == 2) {
            alrmValue = "到位感应断开异常";
        }
        else if (alrmCode == 3) {
            alrmValue = "到位感应接通异常";
        }
        else if (alrmCode == 4) {
            alrmValue = "托盘信息丢失报警(请检查目标编号和条码)";
        }
        else if (alrmCode == 5) {
            alrmValue = "托盘信息未清除报警(请检查目标编号和条码)";
        }
        else if (alrmCode == 6) {
            alrmValue = "托盘信息错误报警(检查目标编号是否错误)";
        }
        else if (alrmCode == 7) {
            alrmValue = "任务申请时托盘条码异常";
        }
        else if (alrmCode == 8) {
            alrmValue = "WCS响应超时报警";
        }
        else if (alrmCode == 9) {
            alrmValue = "WCS反馈托盘目的地址错误";
        }
        else if (alrmCode == 10) {
            alrmValue = "扫码超时报警";
        }
        else if (alrmCode == 11) {
            alrmValue = "扫码NG报警";
        }
        else if (alrmCode == 12) {
            alrmValue = "托盘信息错误报警(检查目标编号是否错误)";
        }
        else if (alrmCode == 13) {
            alrmValue = "入料后无条码报警";
        }
        else if (alrmCode == 14) {
            alrmValue = "顶升行程开关感应1异常报警";
        }
        else if (alrmCode == 15) {
            alrmValue = "顶升行程开关感应2异常报警";
        }
        else if (alrmCode == 16) {
            alrmValue = "托盘条码校验失败报警";
        }
        else if (alrmCode == 17) {
            alrmValue = "滚筒无料有条码报警";
        }
        else if (alrmCode == 18) {
            alrmValue = "滚筒有料无条码报警";
        }
        else if (alrmCode == 19) {
            alrmValue = "货叉感应器断开异常";
        }
        else if (alrmCode == 20) {
            alrmValue = "急停报警";
        }
        else if (alrmCode == 21) {
            alrmValue = "顶升气缸伸出卡阻报警";
        }
        else if (alrmCode == 22) {
            alrmValue = "顶升气缸缩回卡阻报警";
        }
        else if (alrmCode == 23) {
            alrmValue = "顶升气缸检测异常报警";
        }
        else if (alrmCode == 24) {
            alrmValue = "直行大阻挡气缸伸出卡阻报警";
        }
        else if (alrmCode == 25) {
            alrmValue = "直行大阻挡气缸缩回卡阻报警";
        }
        else if (alrmCode == 26) {
            alrmValue = "直行大阻挡气缸检测异常报警";
        }
        else if (alrmCode == 27) {
            alrmValue = "直行小阻挡气缸伸出卡阻报警";
        }
        else if (alrmCode == 28) {
            alrmValue = "直行小阻挡气缸缩回卡阻报警";
        }
        else if (alrmCode == 29) {
            alrmValue = "直行小阻挡气缸检测异常报警";
        }
        else if (alrmCode == 30) {
            alrmValue = "左侧大阻挡气缸伸出卡阻报警";
        }
        else if (alrmCode == 31) {
            alrmValue = "左侧大阻挡气缸缩回卡阻报警";
        }
        else if (alrmCode == 32) {
            alrmValue = "左侧大阻挡气缸检测异常报警";
        }
        else if (alrmCode == 33) {
            alrmValue = "左侧小阻挡气缸伸出卡阻报警";
        }
        else if (alrmCode == 34) {
            alrmValue = "左侧小阻挡气缸缩回卡阻报警";
        }
        else if (alrmCode == 35) {
            alrmValue = "左侧小阻挡气缸检测异常报警";
        }
        else if (alrmCode == 36) {
            alrmValue = "右侧大阻挡气缸伸出卡阻报警";
        }
        else if (alrmCode == 37) {
            alrmValue = "右侧大阻挡气缸缩回卡阻报警";
        }
        else if (alrmCode == 38) {
            alrmValue = "右侧大阻挡气缸检测异常报警";
        }
        else if (alrmCode == 39) {
            alrmValue = "右侧小阻挡气缸伸出卡阻报警";
        }
        else if (alrmCode == 40) {
            alrmValue = "右侧小阻挡气缸缩回卡阻报警";
        }
        else if (alrmCode == 41) {
            alrmValue = "右侧小阻挡气缸检测异常报警";
        }
        else if (alrmCode == 42) {
            alrmValue = "线体电动滚筒报警";
        }
        else if (alrmCode == 43) {
            alrmValue = "移栽电动滚筒报警";
        }
        else if (alrmCode == 44) {
            alrmValue = "前段入料超时报警";
        }
        else if (alrmCode == 45) {
            alrmValue = "左段入料超时报警";
        }
        else if (alrmCode == 46) {
            alrmValue = "右段入料超时报警";
        }
        else if (alrmCode == 47) {
            alrmValue = "托盘类型异常报警";
        }
        else if (alrmCode == 48) {
            alrmValue = "托盘放反";
        }
        else if (alrmCode == 49) {
            alrmValue = "四面条码扫码NG报警";
        }
        else if (alrmCode == 50) {
            alrmValue = "电芯条码扫码NG报警";
        }
       //机器人报警
        else if (alrmCode == 51) {
            alrmValue = "机器人夹爪柔性检测异常";
        } else if (alrmCode == 52) {
            alrmValue = "机器人夹爪探测检测异常";
        } else if (alrmCode == 53) {
            alrmValue = "机器人夹爪窄边电池检测异常";
        } else if (alrmCode == 54) {
            alrmValue = "机器人夹爪宽边电池检测异常";
        } else if (alrmCode == 55) {
            alrmValue = "机器人夹爪窄边夹紧到位异常";
        } else if (alrmCode == 56) {
            alrmValue = "机器人夹爪窄边张开到位异常";
        } else if (alrmCode == 57) {
            alrmValue = "机器人夹爪宽边夹紧到位异常";
        } else if (alrmCode == 58) {
            alrmValue = "机器人夹爪宽边张开到位异常";
        } else if (alrmCode == 59) {
            alrmValue = "电池类型异常";
        } else if (alrmCode == 60) {
            alrmValue = "任务号异常";
        } else if (alrmCode == 61) {
            alrmValue = "位置号异常";
        } else if (alrmCode == 62) {
            alrmValue = "机器人等待任务超时";
        } else if (alrmCode == 63) {
            alrmValue = "机器人等待取料超时";
        } else if (alrmCode == 64) {
            alrmValue = "机器人等待取料完成超时";
        } else if (alrmCode == 65) {
            alrmValue = "机器人等待放料超时";
        } else if (alrmCode == 66) {
            alrmValue = "机器人等待放料完成超时";
        } else if (alrmCode == 67) {
            alrmValue = "取料完成后机器人感应无料";
        } else if (alrmCode == 68) {
            alrmValue = "取料完成后机器人感应无信息";
        } else if (alrmCode == 69) {
            alrmValue = "机器人感应电池无信息报警";
        } else if (alrmCode == 70) {
            alrmValue = "机器人电池有信息无感应报警";
        } else if (alrmCode == 71) {
            alrmValue = "移动X轴故障";
        } else if (alrmCode == 72) {
            alrmValue = "移动X轴正极限报警";
        } else if (alrmCode == 73) {
            alrmValue = "移动X轴负极限报警";
        } else if (alrmCode == 74) {
            alrmValue = "顶升Y1轴故障";
        } else if (alrmCode == 75) {
            alrmValue = "顶升Y1轴正极限报警";
        } else if (alrmCode == 76) {
            alrmValue = "顶升Y1轴负极限报警";
        } else if (alrmCode == 77) {
            alrmValue = "顶升Y2轴故障";
        } else if (alrmCode == 78) {
            alrmValue = "顶升Y2轴正极限报警";
        } else if (alrmCode == 79) {
            alrmValue = "顶升Y2轴负极限报警";
        } else if (alrmCode == 80) {
            alrmValue = "托盘放反检感应异常";
        } else if (alrmCode == 81) {
            alrmValue = "MES反馈信息中无电池类型";
        } else if (alrmCode == 82) {
            alrmValue = "MES提示信息不对,需人工确认";
        } else if (alrmCode == 83) {
            alrmValue = "托盘条码校验失败报警";
        } else if (alrmCode == 84) {
            alrmValue = "1#顶升轴回原未完成";
        } else if (alrmCode == 85) {
            alrmValue = "2#顶升轴回原未完成";
        } else if (alrmCode == 86) {
            alrmValue = "移动轴回原未完成";
        } else if (alrmCode == 87) {
            alrmValue = "安全门开报警7";
        } else if (alrmCode == 88) {
            alrmValue = "安全门急停报警";
        }

        else if (alrmCode == 101) {
            alrmValue = "提升机急停报警";
        }
        else if (alrmCode == 102) {
            alrmValue = "提升机上限位报警";
        }
        else if (alrmCode == 103) {
            alrmValue = "提升机下限位报警";
        }
        else if (alrmCode == 104) {
            alrmValue = "提升机左限位报警";
        }
        else if (alrmCode == 105) {
            alrmValue = "提升机左限位报警";
        }
        else if (alrmCode == 106) {
            alrmValue = "提升机变频器错误报警";
        }
        else if (alrmCode == 107) {
            alrmValue = "提升机WCS行层信息发送错误报警";
        }
        else if (alrmCode == 108) {
            alrmValue = "提升机HMI行层信息发送错误报警";
        }
        else if (alrmCode == 109) {
            alrmValue = "提升机输送电机取料超时报警";
        }
        else if (alrmCode == 110) {
            alrmValue = "提升机输送电机放料超时报警";
        }
        else if (alrmCode == 111) {
            alrmValue = "提升机定位位置错误报警";
        }
        else if (alrmCode == 112) {
            alrmValue = "提升机定位到达位置与实际位置不符报警";
        }
        else if (alrmCode == 113) {
            alrmValue = "提升机运行中托盘撞到左极限报警";
        }
        else if (alrmCode == 114) {
            alrmValue = "提升机运行中托盘撞到右极限报警";
        }

        else if (alrmCode == 151) {
            alrmValue = "电芯扫码超时报警";
        }
        else if (alrmCode == 152) {
            alrmValue = "电芯扫码NG报警";
        }
        else if (alrmCode == 153) {
            alrmValue = "托盘方向异常";
        }
        else if (alrmCode == 154) {
            alrmValue = "扫码次数少于电池数量";
        }
        else if (alrmCode == 155) {
            alrmValue = "WCS反馈校验完成超时报警";
        }
        else if (alrmCode == 156) {
            alrmValue = "托盘扫码超时报警";
        }
        else if (alrmCode == 157) {
            alrmValue = "托盘扫码NG报警";
        }
        else if (alrmCode == 158) {
            alrmValue = "WCS回复电池数量和类型异常";
        }
        else if (alrmCode == 159) {
            alrmValue = "扫码次数超出电池数量";
        }
        else if (alrmCode == 160) {
            alrmValue = "电池条码数据异常，请排查";
        }
        else if (alrmCode == 161) {
            alrmValue = "定位数据输入错误";
        }
        else if (alrmCode == 162) {
            alrmValue = "X轴报警";
        }
        else if (alrmCode == 163) {
            alrmValue = "X轴报警";
        }
        else if (alrmCode == 164) {
            alrmValue = "Z轴报警";
        }

        //以下是OCV报警
        else if (alrmCode == 170) {
            alrmValue = "扫码NG报警";
        }
        else if (alrmCode == 171) {
            alrmValue = "感应器异常报警";
        }
        else if (alrmCode == 172) {
            alrmValue = "WCS回复超时";
        }
        else if (alrmCode == 173) {
            alrmValue = "WCS未回复新目的地址";
        }
        else if (alrmCode == 174) {
            alrmValue = "入料超时报警";
        }
        else if (alrmCode == 175) {
            alrmValue = "出料超时报警";
        }
        else if (alrmCode == 176) {
            alrmValue = "扫码失败报警";
        }
        else if (alrmCode == 177) {
            alrmValue = "托盘歪斜报警";
        }
        else if (alrmCode == 178) {
            alrmValue = "托盘条码校验失败";
        }
        else if (alrmCode == 179) {
            alrmValue = "轴未回原报警";
        }
        else if (alrmCode == 180) {
            alrmValue = "X轴定位时间过长报警";
        }
        else if (alrmCode == 181) {
            alrmValue = "Y轴定位时间过长报警";
        }
        else if (alrmCode == 182) {
            alrmValue = "探针Z轴定位时间过长报警";
        }
        else if (alrmCode == 183) {
            alrmValue = "NG数量过大，请人工确认";
        }
        else if (alrmCode == 184) {
            alrmValue = "电池放反报警";
        }
        else if (alrmCode == 185) {
            alrmValue = "电池内阻无穷大请确认";
        }
        else if (alrmCode == 186) {
            alrmValue = "OCV检测次数报警";
        }
        else if (alrmCode == 187) {
            alrmValue = "OCV线体托盘放反报警";
        }
        else if (alrmCode == 188) {
            alrmValue = "OCV电动滚筒报警";
        }
        else if (alrmCode == 189) {
            alrmValue = "OCV顶升气缸伸出卡阻报警";
        }
        else if (alrmCode == 190) {
            alrmValue = "OCV顶升气缸缩回卡阻报警";
        }
        else if (alrmCode == 191) {
            alrmValue = "OCV顶升气缸检测异常报警";
        }
        else if (alrmCode == 192) {
            alrmValue = "OCV阻挡气缸伸出卡阻报警";
        }
        else if (alrmCode == 193) {
            alrmValue = "OCV阻挡气缸缩回卡阻报警";
        }
        else if (alrmCode == 194) {
            alrmValue = "OCV阻挡气缸检测异常报警";
        }
        else if (alrmCode == 195) {
            alrmValue = "OCV防反气缸伸出卡阻报警";
        }
        else if (alrmCode == 196) {
            alrmValue = "OCV防反气缸缩回卡阻报警";
        }
        else if (alrmCode == 197) {
            alrmValue = "OCV防反气缸检测异常报警";
        }
        else if (alrmCode == 198) {
            alrmValue = "急停报警";
        }
        else if (alrmCode == 199) {
            alrmValue = "上位机信息异常报警";
        }
        else if (alrmCode == 200) {
            alrmValue = "入料超时报警";
        }
        else if (alrmCode == 201) {
            alrmValue = "出料超时报警";
        }
        else if (alrmCode == 202) {
            alrmValue = "物流线入料不在自动模式报警";
        }
        else if (alrmCode == 203) {
            alrmValue = "物流线出料不在自动模式报警";
        }
        else if (alrmCode == 204) {
            alrmValue = "后门_右上门被打开_I2.4";
        }
        else if (alrmCode == 205) {
            alrmValue = "后门_左上门被打开_I2.5";
        }
        else if (alrmCode == 206) {
            alrmValue = "后门_右下门被打开 I2.6";
        }
        else if (alrmCode == 207) {
            alrmValue = "后门_左下门被打开 I2.7";
        }
        else if (alrmCode == 208) {
            alrmValue = "前门_左上门被打开 I3.0";
        }
        else if (alrmCode == 209) {
            alrmValue = "前门_右上门被打开 I3.1";
        }
        else if (alrmCode == 210) {
            alrmValue = "前门_右下门被打开 I4.0";
        }
        else if (alrmCode == 211) {
            alrmValue = "前门_左下门被打开 I4.1";
        }
        else if (alrmCode == 212) {
            alrmValue = "X轴故障报警";
        }
        else if (alrmCode == 213) {
            alrmValue = "X轴正极限报警故障";
        }
        else if (alrmCode == 214) {
            alrmValue = "X轴负极限报警故障";
        }
        else if (alrmCode == 215) {
            alrmValue = "Y轴故障报警";
        }
        else if (alrmCode == 216) {
            alrmValue = "Y轴正极限报警";
        }
        else if (alrmCode == 217) {
            alrmValue = "Y轴负极限报警";
        }
        else if (alrmCode == 218) {
            alrmValue = "探针Z轴故障报警";
        }
        else if (alrmCode == 219) {
            alrmValue = "探针Z轴正极限报警";
        }
        else if (alrmCode == 220) {
            alrmValue = "探针Z轴负极限报警";
        }
        else if (alrmCode == 221) {
            alrmValue = "PC其他异常";
        }
        else if (alrmCode == 222) {
            alrmValue = "PC请求移动失败";
        }
        else if (alrmCode == 223) {
            alrmValue = "PC投切板换失败";
        }
        else if (alrmCode == 224) {
            alrmValue = "PC复位内阻仪失败";
        }
        else if (alrmCode == 225) {
            alrmValue = "PC内阻清零失败";
        }
        else if (alrmCode == 226) {
            alrmValue = "PC请求PLC抬起失败";
        }
        else if (alrmCode == 227) {
            alrmValue = "PC查询配方信息失败";
        }
        else if (alrmCode == 228) {
            alrmValue = "PC通知PLC完成失败";
        }
        else if (alrmCode == 229) {
            alrmValue = "PC向WMS上传测试数据失败";
        }
        else if (alrmCode == 230) {
            alrmValue = "PC向MES上传测试数据失败";
        }
        else if (alrmCode == 231) {
            alrmValue = "PC保存电芯测试数据失败";
        }
        else if (alrmCode == 232) {
            alrmValue = "门禁屏蔽开启";
        }
        else if (alrmCode == 233) {
            alrmValue = "PN掉线报警";
        }
        else if (alrmCode == 234) {
            alrmValue = "CPU掉线报警";
        }
        else if (alrmCode == 235) {
            alrmValue = "X轴掉线报警";
        }
        else if (alrmCode == 236) {
            alrmValue = "Y轴掉线报警";
        }
        else if (alrmCode == 237) {
            alrmValue = "Z轴掉线报警";
        }
        else if (alrmCode == 238) {
            alrmValue = "扫码枪掉线报警";
        }
        else if (alrmCode == 239) {
            alrmValue = "IO模块掉线报警";
        }
        else if (alrmCode == 240) {
            alrmValue = "PC允许测试超时报警";
        }
        else if (alrmCode == 241) {
            alrmValue = "PC反馈电芯负压过多报警";
        } else {
            alrmValue = alrmCode;
        }
        return "<font color=\"red\">" + alrmValue + "</font>";
    } else {
        return alrmValue;
    }
}


function plcAllScAlrmShow(alrmCode) {

    if (parseInt(alrmCode) > 0) {
        if (alrmCode == 1) {
            return "急停报警";
        }
        if (alrmCode == 2) {
            return "X轴正限位报警";
        }
        if (alrmCode == 3) {
            return "X轴负限位报警";
        }
        if (alrmCode == 4) {
            return "Y轴正限位报警";
        }
        if (alrmCode == 5) {
            return "Y轴负限位报警";
        }
        if (alrmCode == 6) {
            return "Z轴正限位报警";
        }
        if (alrmCode == 7) {
            return "Z轴负限位报警";
        }
        if (alrmCode == 10) {
            return "X轴变频器报错";
        }
        if (alrmCode == 11) {
            return "Y轴变频器报错";
        }
        if (alrmCode == 12) {
            return "Z轴变频器报错";
        }
        if (alrmCode == 14) {
            return "行列层选择错误";
        }
        if (alrmCode == 15) {
            return "货架有料，Z轴放料错误";
        }
        if (alrmCode == 16) {
            return "Z轴放料完成后，检测货叉有料错误";
        }
        if (alrmCode == 17) {
            return "Z轴取料完成后，检测货叉无料错误";
        }
        if (alrmCode == 18) {
            return "Z轴运动过程中，检测货物超高报警";
        }
        if (alrmCode == 19) {
            return "升降门动作超时报警";
        }
        if (alrmCode == 20) {
            return "Z轴检测货物超出超高，禁止启动";
        }
        if (alrmCode == 21) {
            return "Z轴防火门不在上位，禁止启动";
        }
        if (alrmCode == 22) {
            return "检测到障碍物，请勿启动";
        }
        if (alrmCode == 23) {
            return "Z轴检测有料，请勿启动取料";
        }
        if (alrmCode == 24) {
            return "Z轴检测无料，请勿启动放料";
        }
        if (alrmCode == 25) {
            return "请将开关打到自动再启动自动模式";
        }
        if (alrmCode == 26) {
            return "请将开关打到手动再启动模拟自动";
        }
        if (alrmCode == 27) {
            return "没有给轴赋自动运行速度，请勿启动";
        }
        if (alrmCode == 28) {
            return "X轴手动条件不满足报警";
        }
        if (alrmCode == 32) {
            return "Y轴手动条件不满足报警";
        }
        if (alrmCode == 33) {
            return "Z轴手动条件不满足报警";
        }
        if (alrmCode == 35) {
            return "X轴运行过程中检测到障碍物停车";
        }
        if (alrmCode == 36) {
            return "自动中门禁打开报警";
        }
        if (alrmCode == 37) {
            return "障碍物传感器故障报错";
        }
        if (alrmCode == 38) {
            return "模拟自动没有退出，不能操作";
        }
        if (alrmCode == 39) {
            return "升降电机安全钳动作报警";
        }
        if (alrmCode == 40) {
            return "Y轴限速&松绳报警";
        }
        if (alrmCode == 41) {
            return "X轴当前值超出报警";
        }
        if (alrmCode == 42) {
            return "Y轴当前值超出报警";
        }
        if (alrmCode == 43) {
            return "X轴定位目标值超出报警";
        }
        if (alrmCode == 44) {
            return "Y轴定位目标值超出报警";
        }
        if (alrmCode == 45) {
            return "X轴运动过程中，检测货物超出报警";
        }
        if (alrmCode == 46) {
            return "货叉防撞机报警";
        }
        if (alrmCode == 47) {
            return "Y轴升降距离超出报警";
        }
        if (alrmCode == 48) {
            return "安全门不在报警";
        }
        if (alrmCode == 49) {
            return "Z轴取料取料前判断无物料报警";
        }
        if (alrmCode == 50) {
            return "堆垛机站台安全门开报警";
        }
        if (alrmCode == 51) {
            return "压床状态无法取/放托盘";
        }
        if (alrmCode == 53) {
            return "分容柜门开启报警";
        }
        if (alrmCode == 54) {
            return "二层取料口不允许堆垛机取料";
        }
        if (alrmCode == 55) {
            return "三层取料口不允许堆垛机取料";
        }
        if (alrmCode == 56) {
            return "消防水箱不允许取料提示";
        }
        if (alrmCode == 57) {
            return "二层堆垛机取料完成线体没有复位允许取料信号";
        }
        if (alrmCode == 58) {
            return "三层堆垛机取料完成线体没有复位允许取料信号";
        }
        if (alrmCode == 59) {
            return "一层线体不允许堆垛机放料";
        }
        if (alrmCode == 60) {
            return "四层线体不允许堆垛机放料";
        }
        if (alrmCode == 61) {
            return "一层堆垛机放料完成线体没有复位允许放料信号";
        }
        if (alrmCode == 62) {
            return "四层堆垛机放料完成线体没有复位允许放料信号";
        }
        if (alrmCode == 63) {
            return "盘点模式下，取料感应无料异常报警";
        }
        if (alrmCode == 64) {
            return "流程超时报警";
        }
        return alrmCode;
    }
}